Skip to content

ci: make Codex review repair single-pass#558

Merged
BigSimmo merged 1 commit into
mainfrom
codex/codex-review-single-pass
Jul 13, 2026
Merged

ci: make Codex review repair single-pass#558
BigSimmo merged 1 commit into
mainfrom
codex/codex-review-single-pass

Conversation

@BigSimmo

Copy link
Copy Markdown
Owner

Summary

  • limit automatic Codex repair to one pass for the lifetime of a pull request
  • resolve only the exact review thread after a trusted Codex disposition marker
  • prevent repair commits from triggering fresh automatic reviews or standalone findings
  • keep repository contents read-only while granting the narrow pull-request permission required for thread resolution

Why

The previous head-scoped three-cycle flow could repeatedly review and repair the same pull request. This makes the lifecycle deterministic and closes completed threads without creating another review loop.

Validation

  • npm run check:codex-autofix-workflow
  • npm run check:github-actions
  • npm run test -- tests/codex-autofix-workflow.test.ts (22 passed)
  • targeted ESLint
  • Prettier and git diff --check

No hosted workflow was triggered or rerun during local validation.

@coderabbitai

coderabbitai Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Codex auto-resolve now performs single-pass, pull-request-scoped deduplication and closes only explicitly authorized review threads using a resolved-disposition marker. Workflow validation, repository guidance, and tests enforce the updated behavior.

Changes

Codex thread resolution

Layer / File(s) Summary
Resolution policy and prompt contract
AGENTS.md, docs/codex-review-protocol.md, .github/workflows/...
Instructions require one automatic repair pass and marker-prefixed replies for eligible thread closure while leaving blocked threads open.
Workflow thread resolution and deduplication
.github/workflows/codex-autofix-review-comments.yml
The workflow uses pull-request-scoped deduplication, requires pull-requests: write, maps authorized replies to review threads, and calls resolveReviewThread.
Workflow validation and behavior tests
scripts/check-codex-autofix-workflow.mjs, tests/codex-autofix-workflow.test.ts
Validation and tests cover permissions, marker requirements, single-pass behavior, GraphQL calls, successful resolution, and visible failures.

Estimated code review effort: 4 (Complex) | ~45 minutes

Sequence Diagram(s)

sequenceDiagram
  participant Codex trusted connector bot
  participant GitHub Actions workflow
  participant GitHub GraphQL API
  Codex trusted connector bot->>GitHub Actions workflow: post marker-prefixed disposition reply
  GitHub Actions workflow->>GitHub GraphQL API: locate matching review thread
  GitHub Actions workflow->>GitHub GraphQL API: call resolveReviewThread
  GitHub GraphQL API-->>GitHub Actions workflow: return resolution result or error
Loading

Possibly related PRs

  • BigSimmo/Database#435: Overlaps the workflow’s single-pass, PR-scoped deduplication, and marker-based thread closure.
  • BigSimmo/Database#454: Overlaps validation of Codex auto-fix protocol, markers, and permissions.
  • BigSimmo/Database#455: Overlaps deduplication, repair-pass limits, trusted bot handling, and resolved-thread gating.

Caution

Pre-merge checks failed

Please resolve all errors before merging. Addressing warnings is optional.

  • Ignore

❌ Failed checks (1 error, 1 warning)

Check name Status Explanation Resolution
Verification Claims ❌ Error The PR description’s Validation section cites ESLint, Prettier, and git diff --check without explicit command/result pairs; only the test line states a result. Rewrite validation notes as explicit command/result pairs, e.g. 'Ran npm run test -- tests/codex-autofix-workflow.test.ts: passed' or 'Not run: reason', and do the same for ESLint/Prettier/checks.
Description check ⚠️ Warning It covers summary, why, and validation, but omits the required checklist-style Verification section from the template. Add the template's Verification checklist items, including the required npm run verify:pr-local entry and any applicable optional checks.
✅ Passed checks (9 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: making Codex review repair single-pass.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Generated And Sensitive Files ✅ Passed Only workflow/docs/script/test text changed; no secrets, credentials, keys, .envs, logs, caches, or build artifacts were committed.
Risky Git Or Deployment Actions ✅ Passed No added instructions recommend force-push, reset --hard, destructive cleanup, branch deletion, rebasing shared branches, or deployment; changed docs explicitly forbid them.
Supabase Project And Schema Safety ✅ Passed PR only changes Codex review workflow docs/scripts/tests; no Supabase project refs, env examples, migrations, policies, or schema/data files were touched.
Runtime And Package Manager Integrity ✅ Passed PR only changes the Codex workflow/docs/tests; package.json, package-lock.json, .nvmrc, and .node-version still enforce Node 24/npm 11.
Api Route Failure Handling ✅ Passed PASS: This PR only changes a GitHub Actions workflow/docs/tests, and the workflow has explicit failure handling for 403s, missing threads, and guarded thread resolution.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/codex-review-single-pass
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch codex/codex-review-single-pass

Comment @coderabbitai help to get the list of available commands.

@supabase

supabase Bot commented Jul 13, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project sjrfecxgysukkwxsowpy because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@BigSimmo
BigSimmo marked this pull request as ready for review July 13, 2026 07:58
@BigSimmo
BigSimmo merged commit 0d7104a into main Jul 13, 2026
15 checks passed
@BigSimmo
BigSimmo deleted the codex/codex-review-single-pass branch July 13, 2026 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant